Skip to content

Support multi images for vlm benchmarking in samples and llm_bench #2197

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Conversation

wgzintel
Copy link
Contributor

@wgzintel wgzintel commented May 12, 2025

  1. tools/llm_bench supports multiple images for benchmarking of vlm models.
  2. samples/cpp/visual_language_chat supports multiple images for benchmarking of vlm models.
  3. samples/cpp/text_generation supports to read prompt from file.

@github-actions github-actions bot added category: llm_bench Label for tool/llm_bench folder category: LLM samples GenAI LLM samples category: VLM samples GenAI VLM samples labels May 12, 2025
@wgzintel wgzintel requested a review from peterchen-intel May 12, 2025 09:55
@wgzintel wgzintel changed the title Support multi images for vlm test Support multi images for vlm benchmarking in samples and llm_bench May 13, 2025
@Wovchena Wovchena requested a review from Copilot June 19, 2025 07:20
Copy link
Contributor

@Copilot Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull Request Overview

This PR adds support for handling multiple images in VL benchmarking and enhances the prompt configuration by allowing prompt file input across Python and C++ samples.

  • Updated image loading logic in both Python and C++ to handle directories of images.
  • Modified prompt handling to allow reading from files and set default prompts accordingly.
  • Documentation and build script updates to reflect the new user options.

Reviewed Changes

Copilot reviewed 13 out of 13 changed files in this pull request and generated 1 comment.

Show a summary per file
File Description
tools/llm_bench/task/visual_language_generation.py Uses directory-checks to load multiple images and logs the image count.
samples/python/visual_language_chat/benchmark_vlm.py Introduces prompt file support and updates image loading to handle multiple images.
samples/python/visual_language_chat/README.md Updates command line options documentation for prompt and image inputs.
samples/python/text_generation/benchmark_genai.py Modifies prompt handling to support file input and consistent list formatting for tokenization.
samples/cpp/visual_language_chat/benchmark_vlm.cpp Updates image loading to support multiple images and integrates prompt file reading.
samples/cpp/visual_language_chat/README.md Updates documentation to reflect prompt file and multi-image support.
samples/cpp/visual_language_chat/CMakeLists.txt Adjusts the build configuration to include the new source for prompt file reading.
samples/cpp/text_generation/read_prompt_from_file.{h,cpp} Introduces utility functions to read prompts from a file.
samples/cpp/text_generation/benchmark_genai.cpp Similar prompt handling updates with multi-image and prompt file support.
samples/cpp/text_generation/README.md Reflects updated command line options for prompt configuration.
samples/cpp/text_generation/CMakeLists.txt Adjusts the build configuration to include the new prompt file reader utility.

@Wovchena Wovchena enabled auto-merge June 20, 2025 06:59
@Wovchena Wovchena added this pull request to the merge queue Jun 20, 2025
@github-merge-queue github-merge-queue bot removed this pull request from the merge queue due to a conflict with the base branch Jun 20, 2025
@wgzintel wgzintel added this pull request to the merge queue Jun 22, 2025
@github-merge-queue github-merge-queue bot removed this pull request from the merge queue due to failed status checks Jun 22, 2025
@Wovchena Wovchena added this pull request to the merge queue Jun 22, 2025
Merged via the queue into openvinotoolkit:master with commit 9a63488 Jun 22, 2025
68 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
category: cmake / build Cmake scripts category: llm_bench Label for tool/llm_bench folder category: LLM samples GenAI LLM samples category: VLM samples GenAI VLM samples
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants